import React from 'react'
import PropTypes from 'prop-types'

class ProductsList extends React.Component {
  render() {
    const { title, children } = this.props
    return (
      <div>
        <h3>{title}</h3>
        <div>{children}</div>
      </div>
    )
  }
}

ProductsList.propTypes = {
  children: PropTypes.node,
  title: PropTypes.string.isRequired,
}

export default ProductsList
